package com.shensi.api.admin.client.customer;

import com.shensi.api.admin.client.fallback.customer.CustomerCardSettingDetailClientFallBack;
import com.shensi.api.admin.domian.customer.dto.CustomerCardSettingDetailDto;
import com.shensi.common.core.constant.CloudConstant;
import com.shensi.common.core.domain.AjaxResult;
import com.shensi.common.core.page.TableDataInfo;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @author: budian
 * @since: 2023/11/30
 */
@FeignClient(
        value = CloudConstant.ADMIN_SERVER,
        fallbackFactory = CustomerCardSettingDetailClientFallBack.class)
@Component
public interface CustomerCardSettingDetailClient {

    /**
     * 查询客户电子会员卡充值优惠设置明细列表
     */
    @GetMapping("/customer/detail/list")
    @ApiOperation("查询客户电子会员卡充值优惠设置明细列表")
    public TableDataInfo list(@SpringQueryMap CustomerCardSettingDetailDto customerCardSettingDetail);


    @GetMapping("/customer/detail/listDetailInfo")
    public TableDataInfo listDetailInfo(@SpringQueryMap CustomerCardSettingDetailDto customerCardSetting);

    /**
     * 获取客户电子会员卡充值优惠设置明细详细信息
     */
    @GetMapping(value = "/customer/detail/getInfo/{id}")
    public AjaxResult getInfo(@PathVariable("id") Long id);

    /**
     * 新增客户电子会员卡充值优惠设置明细
     */
    @PostMapping("/customer/detail")
    public AjaxResult add(@RequestBody CustomerCardSettingDetailDto customerCardSettingDetail);

    /**
     * 新增客户电子会员卡充值优惠设置明细
     */
    @PostMapping("/customer/detail/addConsumeActivity")
    public AjaxResult addConsumeActivity(@RequestBody CustomerCardSettingDetailDto customerCardSettingDetail);


    /**
     * 修改客户电子会员卡充值优惠设置明细
     */
    @PutMapping("/customer/detail")
    public AjaxResult edit(@RequestBody CustomerCardSettingDetailDto customerCardSettingDetail);

    /**
     * 逻辑删除油站信息
     */
    @PostMapping(value = "/customer/detail/deleteDetail")
    public AjaxResult deleteDetail(@RequestBody CustomerCardSettingDetailDto detail);



    /**
     * 逻辑删除油站信息
     */
    @DeleteMapping(value = "/customer/detail/deleteDetails/{ids}")
    public AjaxResult deleteDetails(@PathVariable("ids") Long[] ids);

    /**
     * 删除客户电子会员卡充值优惠设置明细
     */
    @DeleteMapping("/customer/detail/{ids}")
    public AjaxResult remove(@PathVariable("ids") Long[] ids);

    /**
     * 更新充值活动状态
     */
    @GetMapping("/customer/detail/updateStatus/{status}/{ids}")
    public AjaxResult updateStatus(@PathVariable("status") String status,@PathVariable("ids") Long[] ids);

}
